<!DOCTYPE html>
<!--
To change this license header, choose License Headers in Project Properties.
To change this template file, choose Tools | Templates
and open the template in the editor.
-->
<html>
    <head>
        <title>Idea Website</title>
        <meta charset="UTF-8">
        <meta name="viewport" content="width=device-width">
        <link href="<?php echo CSS_User_URL; ?> /User_Layout_style.css" rel="stylesheet" type="text/css">
        <link href="<?php echo Yii::app()->baseUrl; ?> /vendor/Ladda-master/dist/ladda.min.css" rel="stylesheet" type="text/css">
        <!--<script src="http://code.jquery.com/jquery-2.1.1.min.js" type="text/javascript"></script>-->   
        <?php
        Yii::app()->clientScript->registerScriptFile((Yii::app()->baseUrl) . '/vendor/Ladda-master/dist/ladda.min.js', CClientScript::POS_HEAD);
        Yii::app()->clientScript->registerScriptFile((Yii::app()->baseUrl) . '/vendor/Ladda-master/dist/spin.min.js', CClientScript::POS_HEAD);
        Yii::app()->clientScript->registerCoreScript('jquery');
        Yii::app()->clientScript->registerCoreScript('jquery.ui');
        ?>
    </head>
    <body>
        <div id="wrapper">
            <header>
                <div id="header">
                    <div id="logo">
                        <a href="index.html">
                            <img src="<?php echo Yii::app()->baseUrl; ?>/images/Logo.png" alt="Ideawebsite.com">
                        </a>
                    </div>
                    <nav id="main_menu" class="center-child">
                        <!--                        <a class="topnav" href="index.html">Trang chủ</a>
                                                <a class="topnav" href="Article_List.html">Bài viết</a>
                                                
                                                <a class="topnav" href="Article_Post.html">Đăng bài viết</a>
                                                <a class="topnav" href="Profile.html">Cá nhân</a>
                                                <a class="topnav" href="Login_site.html">Đăng nhập</a>
                                                <a class="topnav" href="Quick_sign_up.html">Đăng ký nhanh</a>
                                                <a class="topnav" href="#">Liên hệ</a>-->
                        <a class="topnav" href="<?php echo Yii::app()->createUrl("User"); ?>">Trang chủ</a>
                        <?php
                        if (!Yii::app()->user->isGuest) {
                            ?>
                            <a class="topnav" href="<?php echo Yii::app()->createUrl("User/ArticleList"); ?>">Ý Tưởng</a>
                            <a class="topnav" href="<?php echo Yii::app()->createUrl("User/ArticlePost"); ?>">Đăng Ý Tưởng</a>
                            <?php
                        }
                        ?>
                    <!--<a class="topnav" href="<?php echo Yii::app()->createUrl("User/Profile"); ?>">Cá nhân</a>-->
                        <a class="topnav" href="<?php echo Yii::app()->createUrl("User/About"); ?>">Liên hệ</a>
                        <?php
                        if (Yii::app()->user->isGuest) {
                            ?>
                            <a class="topnav" href="<?php echo Yii::app()->createUrl("User/Login"); ?>">Đăng nhập</a>
                            <a class="topnav" href="<?php echo Yii::app()->createUrl("User/Register"); ?>">Đăng kí nhanh</a>                                    
                        <?php } else {
                            ?>
                            <a class="topnav" href="<?php echo Yii::app()->createUrl("User/Profile"); ?>"><?php echo Yii::app()->user->name; ?></a>
                            <a class="topnav" href="<?php echo Yii::app()->createUrl("User/Logout"); ?>">Thoát</a>
                            <?php
                        }
                        ?>
                    </nav>
                </div>
            </header>
            <?php echo $content; ?>
            <div class="line_base"></div>
            <footer>
                <div id="footer" class="center-child">
                    <span>Copyright © 2014 Css Author</span>
                </div>
            </footer>
        </div>





    </body>
</html>

<script src="<?php echo JS_User_URL; ?>/User_Layout_js.js" type="text/javascript"></script>
